package sky.dao;

import sky.domain.ModelObject;
import sky.tro.finders.AbstractFinder;

import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * User: Gauss
 * Date: 19.10.13
 * Time: 13:21
 * To change this template use File | Settings | File Templates.
 */
public interface AbstractDAO<T extends ModelObject> {
    public void add(T t);

    public void edit(T t);

    public void remove(Integer id);

    public List<T> list();

    public T getById(Integer id);

    public T getByName(String name, Boolean isInitialize);

    public List<T> listByFinder(final AbstractFinder finder);
}
